package cn.springcloud.fix.quartz.api.response;

import cn.springcloud.fix.common.core.base.BaseResponse;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

public class ListJobResponse extends BaseResponse {

    private List<JobDefinition> jobList = new ArrayList<>();

    public List<JobDefinition> getJobList() {
        return jobList;
    }

    public void setJobList(List<JobDefinition> jobList) {
        this.jobList = jobList;
    }

    @Data
    public static class JobDefinition {

        /**
         * 主键
         */
        private String id;

        /**
         * job名称
         */
        private String name;

        /**
         * job组
         */
        private String jobGroup;

        /**
         * cron表达式
         */
        private String cronExpression;

        /**
         * job状态，-1：逻辑删除，0-暂停，1-开启
         */
        private Integer jobStatus;
    }
}
